fix: resolve CI build failures in plugin-msw DTS and docs MDX generation#857
fix: resolve CI build failures in plugin-msw DTS and docs MDX generation#857
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…scaping Co-authored-by: hotlong <50353452+hotlong@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR fixes two independent CI build failures on main: a TypeScript type error (TS2345) in plugin-msw where string | string[] options were spread directly into a method expecting string[], and an MDX prerender crash caused by unescaped curly braces in schema descriptions being interpreted as JSX expressions. The auto-generated documentation files are also regenerated to reflect current schema state.
Changes:
- Normalize
string | string[]options tostring[]before passing togetProtocol().getData()inplugin-msw - Escape
{...}patterns in schema-level descriptions in thebuild-docs.tsMDX generator - Regenerate multiple auto-generated MDX documentation files to reflect current schema exports
Reviewed changes
Copilot reviewed 17 out of 17 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
packages/plugins/plugin-msw/src/msw-plugin.ts |
Fixes TS2345 by normalizing string | string[] to string[] before passing to getData() |
packages/spec/scripts/build-docs.ts |
Escapes curly braces in schema descriptions to prevent MDX JSX evaluation errors |
content/docs/references/ui/action.mdx |
Regenerated; removes Action schema section, updates imports to current exports |
content/docs/references/system/translation.mdx |
Regenerated; adds new schema sections for translation-related types |
content/docs/references/system/migration.mdx |
Regenerated; removes ChangeSet, CreateObjectOperation, and MigrationOperation sections |
content/docs/references/system/metadata-persistence.mdx |
Regenerated; adds PackagePublishResult and new MetadataRecord fields |
content/docs/references/integration/translation.mdx |
New auto-generated file for MessageFormat in the integration module |
content/docs/references/integration/misc.mdx |
Regenerated; removes MessageFormat (now in its own file) |
content/docs/references/integration/meta.json |
Adds translation entry to the integration reference nav |
content/docs/references/data/query.mdx |
Regenerated; expands expand field description |
content/docs/references/data/object.mdx |
Regenerated; removes Object schema section, updates imports |
content/docs/references/data/field.mdx |
Regenerated; expands reference field description |
content/docs/references/api/protocol.mdx |
Regenerated; expands expand field descriptions |
content/docs/references/api/odata.mdx |
Regenerated; expands $expand field description |
content/docs/references/api/metadata.mdx |
Regenerated; removes ObjectDefinitionResponse section, updates imports |
content/docs/references/api/contract.mdx |
Regenerated; expands expand field description |
content/docs/references/ai/feedback-loop.mdx |
Regenerated; removes FeedbackLoop and Resolution sections, updates imports |
| --- | ||
|
|
||
|
|
There was a problem hiding this comment.
There are two consecutive --- horizontal rules with only a blank line between them at lines 82–88. The first --- (line 85) appears to be an orphaned divider left over after the FieldTranslation section. This produces a double divider in the rendered docs.
| --- |
Two independent build failures on
main:plugin-msw DTS build error (TS2345)
getDataspreadsstring | string[]options directly into protocol'sgetData()which expectsstring[]. Normalize before passing:Docs prerender crash on
/en/docs/references/system/translationbuild-docs.tsemits schema descriptions into MDX without escaping curly braces.MessageFormatSchema.describe('...simple {variable} replacement')causes MDX to evaluatevariableas a JSX expression →ReferenceError. Applied the same{...}→`{...}`escaping already used for property descriptions (line 173) to schema-level descriptions (line 163).Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.